import Vue from 'vue'
import VueRouter from 'vue-router'
import Home from '../views/Home.vue'

// 首页

// list
const online = () => import ('@/views/list/Online.vue');
const Current = () => import ('@/views/list/current/current.vue');
const Manager = () => import ('@/views/list/manager/manager.vue');
const Dashboard = () => import ('@/views/list/dashboard/dashboard.vue');

// 设置
Vue.use(VueRouter)

const routes = [{
        path: '/',
        name: 'Home',
        component: Home,
        children: [
            // list
            {
                path: 'list/online',
                component: online
            },
            // zhy活期路由
            {
                path: 'list/current',
                name: 'Current',
                component: Current
            },
            {
                path: 'list/managerList',
                name: "Manager",
                component: Manager
            },
            {
                path: '/',
                name: "Dashboard",
                component: Dashboard
            }, {
                path: '/list/regular',
                name: "Regular",
                component: () => import ('@/views/regular/regular.vue')
            }
        ]
    }]

const router = new VueRouter({routes})

export default router
